﻿using System.ComponentModel.DataAnnotations;

namespace PublisherManagementSystem.Models
{
	public class District
	{
		public int DistrictID { get; set; }

		[Required(ErrorMessage = "区县名称不能为空")]
		[Display(Name = "区县")]
		[StringLength(50, ErrorMessage = "区县名称不能超过50个字符")]
		public string DistrictName { get; set; }

		public int CityID { get; set; }

		// 导航属性
		public virtual City City { get; set; }
	}
}
